package valid

import (
	"github.com/astaxie/beego/validation"
	"time"
)

func ValidCreateTask(content string, taskType string, t time.Time) (err *validation.ValidationResult) {
	valid := validation.Validation{}

	if v := valid.Required(content, "content"); !v.Ok {
		return v
	} else if v := valid.Required(taskType, "taskType"); !v.Ok {
		return v
	} else if t.After(time.Now()) {

	}
	return &validation.ValidationResult{Ok: true}
}
